package pw_coding

import (
	"database/sql"
)

// mysql table信息
type COLUMNS struct {
	TABLE_CATALOG            string        `xorm:"varchar(512) notnull 'TABLE_CATALOG'"`
	TABLE_SCHEMA             string        `xorm:"varchar(64) notnull 'TABLE_SCHEMA'"`
	TABLE_NAME               string        `xorm:"varchar(64) notnull 'TABLE_NAME'"`
	COLUMN_NAME              string        `xorm:"varchar(64) notnull 'COLUMN_NAME'"`
	ORDINAL_POSITION         int64         `xorm:"bigint notnull 'ORDINAL_POSITION'"`
	COLUMN_DEFAULT           string        `xorm:"longtext 'ORDINAL_POSITION'"`
	IS_NULLABLE              string        `xorm:"varchar(3) notnull 'IS_NULLABLE'"`
	DATA_TYPE                string        `xorm:"varchar(64) 'DATA_TYPE'"`
	CHARACTER_MAXIMUM_LENGTH sql.NullInt64 `xorm:"bigint 'CHARACTER_MAXIMUM_LENGTH'"`
	CHARACTER_OCTET_LENGTH   sql.NullInt64 `xorm:"bigint 'CHARACTER_OCTET_LENGTH'"`
	NUMERIC_PRECISION        sql.NullInt64 `xorm:"bigint 'NUMERIC_PRECISION'"`
	NUMERIC_SCALE            sql.NullInt64 `xorm:"bigint 'NUMERIC_SCALE'"`
	DATETIME_PRECISION       sql.NullInt64 `xorm:"bigint 'DATETIME_PRECISION'"`
	CHARACTER_SET_NAME       string        `xorm:"varchar(32) 'CHARACTER_SET_NAME'"`
	COLLATION_NAME           string        `xorm:"varchar(32) 'COLLATION_NAME'"`
	COLUMN_TYPE              string        `xorm:"longtext 'COLUMN_TYPE'"`
	COLUMN_KEY               string        `xorm:"varchar(3) 'COLUMN_KEY'"`
	EXTRA                    string        `xorm:"varchar(30) 'EXTRA'"`
	PRIVILEGES               string        `xorm:"varchar(80) 'PRIVILEGES'"`
	COLUMN_COMMENT           string        `xorm:"varchar(1024) 'COLUMN_COMMENT'"`
	GENERATION_EXPRESSION    string        `xorm:"longtext 'GENERATION_EXPRESSION'"`
}
